package com.spudtech.tween
{
    
    
    
    public class SpudVarTween extends SpudNumberTween
    {
        
        protected var _target : Object;
        protected var _variable : Object;
        
        public function SpudVarTween(init_target : *,
                                     init_variable : *,
                                     start_val : Number,
                                     end_val : Number,
                                     step_count : uint,
                                     play_mode : uint = PLAY_ONCE,
                                     init_easer : Function = null,
                                     init_callback : Function = null)
        {
            super(start_val,end_val,step_count,play_mode,init_easer,init_callback);
            
            _target = init_target;
            _variable = init_variable;
            
        }
        
        
        override public function update() : void
        {
            super.update();
            
            _target[_variable] = currentVal;
            
        }
        
    }
    
}
